Step 5: An overview of the most important OpenStackClient commands
Start
Now that you have installed the OpenStack client in Step 4, you will learn some important commands.
To get more information about a specific subcommand, append the --help
flag to it.
To list all commands, you can use the --help
flag:
openstack --help
Server
With the command openstack server
you can create, administrate, or delete a VM.
Here is a list of some common commands:
openstack server add
Adds parameters (Fixed IP, Floating IP, Security group, Volume) to a VMopenstack server create
Creates a VMopenstack server delete
Deletes a VMopenstack server list
Shows a list of all VMsopenstack server remove
Removes parameters (Fixed IP, Floating IP, Security group, Volume) from a VMopenstack server show
Shows all important information about the specified VM
Stack
With the command openstack stack
you are able to administrate complete stacks, like openstack server
for instances.
Here is a list for some common commands:
openstack stack create
Creates a new stackopenstack stack list
Shows a list of all stacksopenstack stack show
Shows all important information about the specified stackopenstack stack delete
Deletes the specified stack
Security Group
Security Groups are used to allow or deny incoming and outgoing network traffic based on IP adresses and ports for VMs.
You can also manage security groups in the OpenStackClient.
Here are some common commands:
openstack security group create
Creates a new security group.openstack security group delete
Deletes a security groupopenstack security group list
Shows a list of all security groupsopenstack security group show
Shows all important information about a security groupopenstack security group rule create
Adds a rule for a security groupopenstack security group rule delete
Deletes a rule in a security group
Network
To create VMs, a network is required. Here are some common network commands:
openstack network create
Creates a new networkopenstack network list
Shows a list of all networksopenstack network show
Shows all important information about a networkopenstack network delete
Deletes a network
Router
For the VMs on your network to reach the internet, you need a router. Here are some common router commands.
openstack router create
Creates a new routeropenstack router delete
Deletes a routeropenstack router add port
Adds a port to a routeropenstack router add subnet
Adds a subnet to a router
Subnet
To use a virtual router correctly, you need a subnet that can be administrated with openstack subnet
. Here are some common commands:
openstack subnet create
Creates a new subnetopenstack subnet delete
Deletes a subnetopenstack subnet show
Shows all infomation about a subnet
Port
Ports connect your VMs to your network. Here are some common commands:
openstack port create
Create a new portopenstack port delete
Deletes a portopenstack port show
Shows all infomation about a port
Volume
Volumes are storage locations that persist across the existence of individual instances. Here are some common commands:
openstack volume create
Creates a new Volumeopenstack volume delete
Deletes a volumeopenstack volume show
Shows all infomation about a volume
Conclusion
Now you know some common OpenStack commands, and have a better overview of the system.
These commands are required in the next steps and form the basis for the rest of the guided tour.
In Step 6, you will create and use your own SSH key pairs.